import request from '@/utils/request.js'
import apis from '@/utils/api'
/**
 * @param {Object} params
 * 业绩管理
 */
export function getPerformanceList(params) {
    return request.globalRequest(apis.getPerformanceList, 'POST', params)
}
export function getOrdersByMonth(params) {
    return request.globalRequest(apis.getOrdersByMonth, 'POST', params)
}
export function getLoanByDate(params) {
    return request.globalRequest(apis.getLoanByDate, 'POST', params)
}
export function notReturnedOrders(params) {
    return request.globalRequest(apis.notReturnedOrders, 'POST', params)
}
export function deletePerformance(params) {
    return request.globalRequest(apis.deletePerformance, 'POST', params)
}
export function savePerformance(params) {
		return JSON.parse(params.params).id ? request.globalRequest(apis.editPerformance, 'POST', params) : request.globalRequest(apis.addPerformance, 'POST', params)
}

export default {
	getPerformanceList,
	getLoanByDate,
	notReturnedOrders,
	deletePerformance,
	savePerformance,
}